/**
 * File: g:\vue\vue-element-admin\src\api\navigation.js
 * Created Date: '2019-01-19 10:21:58
 * Author: 魏巍
 * -----
 * Last Modified: '2019-01-20 12:58:13
 * Modified By: 魏巍
 * -----
 * Copyright (c) 2019 魏巍
 * ------------------------------------
 * Javascript will save your soul!
 */

import request from '@/utils/request'

export function tree(params) {
  return request({
    url: '/menu/tree',
    method: 'get',
    params: params
  })
}

export function edit(id) {
  return request({
    url: `/module/${id}/edit`,
    method: 'get'
  })
}

export function save(params) {
  return request({
    url: `/module`,
    method: 'post',
    data: params
  })
}

export function del(id) {
  return request({
    url: `/module/delete/id/${id}`,
    method: 'get'
  })
}
